<%@ Page Language="C#" AutoEventWireup="true" CodeFile="DisableButtonTest.aspx.cs" Inherits="DisableButtonTest" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Ajax Controls and Extenders - Disable Button Test Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
    
    </div>
        <strong><span style="font-size: 32pt">Disable Button Test</span></strong><br />
        <br />
        <a href="Default.aspx">Goto main page</a><br /> <br />
        Sometimes users will click a button multiple times causing<br />
        multiple postbacks to occur. This extender will disable the<br />
        button and change the button text to the desired display when<br />
        the user clicks it thereby preventing multiple clicks on a button.<br />
        <br />
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        <asp:Button  ID="Button1" runat="server" Text="Click Me!" CausesValidation="false" UseSubmitBehavior="false" OnClick="Button1_Click" />
        <ajaxTools:DisableButtonExtender ID="DisableButtonExtender1" runat="server" TargetControlID="Button1" DisabledText="Please wait..." >
        </ajaxTools:DisableButtonExtender>
        <br /><br />
        This test disables the button and sets the display value.<br />
        It performs a postback and sleeps for 5 seconds to simulate processing.<br />
        It then returns the page to the user with the button reactivated.<br />
        <br /><br />
        <a href="Default.aspx">Goto main page</a>
    </form>
</body>
</html>
